package com.futures.investm.utils;

import android.content.Context;
import android.content.pm.ApplicationInfo;
import android.content.pm.PackageManager;

import static com.umeng.socialize.utils.ContextUtil.getPackageName;

public class ApplicationUtil {
    public  static String getMetaValueFromApp(Context context, String key){
        try {
            ApplicationInfo appInfo = context.getPackageManager().getApplicationInfo(getPackageName(),
                    PackageManager.GET_META_DATA);
            String value = appInfo.metaData.getString(key);
            return value;
        } catch (PackageManager.NameNotFoundException e) {
            e.printStackTrace();
        }
        return "";
    }
}
